Make "parentless" structs inherit from their builtin type
authorStefan Monnier <monnier@iro.umontreal.ca>
Thu, 7 Mar 2024 21:58:15 +0000 (16:58 -0500)
committerStefan Monnier <monnier@iro.umontreal.ca>
Fri, 8 Mar 2024 07:04:57 +0000 (02:04 -0500)
commit7c127fc965fbe781141a6bccbe0b620dc7862b1d
tree85165bede4b72d3c6bc7966ed080b60bf516eb4f
parent76e9c761a45e0157a8ca43eaaf928385d8e0c228
Make "parentless" structs inherit from their builtin type

* lisp/emacs-lisp/cl-preloaded.el (cl--struct-register-child):
Register child only in struct parents.
(cl-struct-define): Put the "type" as parent of parentless :type structs.
Copy slots only from struct parent classes.
(cl-structure-object): Set (manually) its parent to `record`
and remove assertion that it has no parents.
lisp/emacs-lisp/cl-preloaded.el